const state = {
  choicedLive: {},
  isRefresh: []
}

const mutations = {
  SET_CHOICED_LIVE: (state, live) => {
    state.choicedLive = live
  },
  SET_LIVE_REFRESH: (state, isRefresh) => {
    state.isRefresh = isRefresh
  }
}

const actions = {
  // 设置选择的房间
  setchoiceLive({ commit }, live) {
    commit('SET_CHOICED_LIVE', live)
  },
  // 正在直播/即将开始
  setliveTypes({ commit }, isRefresh) {
    commit('SET_LIVE_REFRESH', isRefresh)
  }
}

export default {
  namespaced: true,
  state,
  mutations,
  actions
}
